package com.sheepone.distributor.thread;

import java.util.concurrent.LinkedBlockingQueue;

/**
 * @author Miss.杨
 * @description
 * @since 2023-12-14 17:33
 */
public class DelayEventQueue<T> {
    private final LinkedBlockingQueue<T> queue = new LinkedBlockingQueue<>();

    public T take() throws InterruptedException {
        return queue.take();
    }

    public void put(T t) throws InterruptedException {
        queue.put(t);
    }

    public boolean isEmpty() {
        return queue.isEmpty();
    }
}
